import axios from 'axios'
export const chunkRequest=(chunkList)=>{
    const requestAll=chunkList.map((item) => {
        let formData=new FormData()
        formData.append('chunk',item.chunk)
        formData.append('fileName',item.fileName)
        return axios({
          method: "POST",
          url: "http://127.0.0.1:3000/api/upload_chunk",
          data: formData,
          headers: {
            "Content-Type": "multipart/form-data",
          },
        });
      });
      Promise.all(requestAll)
}